package com.emily.test.service.impl;

import com.emily.test.mapper.OSlideshowMapper;
import com.emily.test.model.OSlideshow;
import com.emily.test.service.SlideshowService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author ：zc
 * @date ：Created in 2019/4/2 9:54
 * @description：
 */
@Service
public class SlideshowServiceImpl implements SlideshowService {
    @Resource
    private OSlideshowMapper oSlideshowMapper;
    @Override
    public int insert(OSlideshow oSlideshow) {
        return oSlideshowMapper.insertSelective(oSlideshow);
    }

    @Override
    public void deleteByIds(int id) {
         oSlideshowMapper.deleteByIds(id);
    }

    @Override
    public int updateNews(OSlideshow oSlideshow) {
        return oSlideshowMapper.update(oSlideshow);
    }

    @Override
    public List<OSlideshow> selectList(String code) {
        return oSlideshowMapper.selectList(code);
    }

    @Override
    public OSlideshow selectOSlideshow(int id) {
        return oSlideshowMapper.selectOSlideshow(id);
    }
}
